package com.zsrt.java.day20161229.cg.demo01;

public class Student {
	/**
	 * 设置年龄
	 */
	public int age =23;
	/**
	 * 设置性别
	 */
	private char sex;
	public char getSex() {
		return sex;
	}

	public void setSex(char sex) {
		this.sex = sex;
	}

	public int getAge() {
		return age;
	}

	public void setAge(int age) {
		if(age>=1 && age<=130){
			this.age = age;
		}
	}
}
